package com.p2p.listener;

import com.p2p.model.P2PRoom;
import com.p2p.model.P2PUser;

import org.webrtc.MediaStream;

/**
 * Implement this interface to be notified of events.
 */
public interface P2PRoomListener {

    boolean checkPermission();

    void onJoinSuccess(P2PRoom room);

    void onStatusChanged(P2PUser user,String newStatus);

    void onLocalStream(MediaStream localStream);

    void onAddRemoteStream(P2PUser user);

    void onRemoveRemoteStream(P2PUser user);

    void onDataChannelTextMessage(P2PUser other, String message);

    void onUserJoined(P2PUser other);

    void onUserLeft(P2PUser other);
}